from django.shortcuts import render
from rest_framework import viewsets
import models
import serializers

class PostViewSet(viewsets.ModelViewSet):
    queryset = models.Posts.objects.all()
    serializer_class = serializers.PostSerializer


class TermViewSet(viewsets.ModelViewSet):
    queryset = models.Term.objects.all()
    serializer_class = serializers.TermSerializer


class LinksViewSet(viewsets.ModelViewSet):
    queryset = models.Links.objects.all()
    serializer_class = serializers.LinkSerializer